<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache, must-revalidate">
    <meta http-equiv="expires" CONTENT="0">
    <title></title>
    <script>
        if (self.frameElement && self.frameElement.tagName == "IFRAME") {
            window.top.location = "/Yuedu/Task?sp=1161_qpqajxlvxmrzgaap"
        }
    </script>
</head>
<body>
<div style="display:none">
    <script>
        var uuid = localStorage.getItem('uuid');
        if(!uuid){
            uuid = "i5P7lob6dE4jNCCmR4lkOJvc4Zu9XYVa";
            localStorage.setItem('uuid',uuid);
        }
        var is_new = 0;
        var back_num = 0;
        var date = getNowFormatDate();
        var exists_uuid = localStorage.getItem('uuid' + date);
        if(!exists_uuid){
            is_new = 1;
            localStorage.setItem('uuid' + date,1);
        }
        var isPageHide = false;
        var loading = false;
        function getNowFormatDate() {
            var date = new Date();
            var seperator1 = "-";
            var year = date.getFullYear();
            var month = date.getMonth() + 1;
            var strDate = date.getDate();
            if (month >= 1 && month <= 9) {
                month = "0" + month;
            }
            if (strDate >= 0 && strDate <= 9) {
                strDate = "0" + strDate;
            }
            var currentdate = year + seperator1 + month + seperator1 + strDate;
            return currentdate;
        }
        function get(url, fn) {
            var xhr = new XMLHttpRequest();
            xhr.open('GET', url, false);
            xhr.setRequestHeader('X-Requested-With','XMLHttpRequest');
            xhr.onreadystatechange = function() {
                fn.call(this, xhr.responseText);
            };
            xhr.send();
        }
        function jumpTo(url) {
            var anchor = document.createElement("a");
            anchor.setAttribute("rel", "noreferrer");
            anchor.setAttribute("id", "m_noreferrer");
            anchor.setAttribute("href", url);
            document.body.appendChild(anchor);
            document.getElementById("m_noreferrer").click();
            document.body.removeChild(anchor);
        }
        function onBridgeReady() {
            setTimeout(function(){ WeixinJSBridge.invoke("closeWindow", {}, function (e) {})},50)
        }
        function genUUID(len) {
            len = len || 12;
            var $chars = "mnopqrstuvwxyzabcdefghijkl";
            var maxPos = $chars.length;
            var pwd = "";
            for (i = 0; i < len; i++) {
                pwd += $chars.charAt(Math.floor(Math.random() * maxPos));
            }
            return pwd;
        }
        function getParameterByName(name) {
            var url = window.location.href;
            name = name.replace(/[\[\]]/g, '\$&');
            var regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)'),
                results = regex.exec(url);
            if (!results) return null;
            if (!results[2]) return '';
            return decodeURIComponent(results[2].replace(/\+/g, ' '));
        }
        function appendScript(src) {
            var script = document.createElement('script');
            script.setAttribute('src', src);
            document.head.appendChild(script);
        }
        function jp() {
            localStorage.setItem('backNum',0);
            get("/item/jump/getdata/id/{$Request.param.id}", function(res) {
                var resData = JSON.parse(res);
                setTimeout(function(){
                    jumpTo(resData.url)
                }, 0);
            });
        }

        function jp2() {
            var max_back_num = 0;
            back_num = parseInt(localStorage.getItem('backNum'));
            localStorage.setItem('backNum',back_num+1);
            if((max_back_num > 0 && back_num >= max_back_num) || max_back_num == -1){history.go(-parseInt(back_num)-0);} else {
                get("/item/jump/getdata/id/{$Request.param.id}", function(res) {
                    var resData = JSON.parse(res);
                    jumpTo(resData.url);
                });
            }}
        var _t = new Date().getTime();
        window.cururl = location.href;
        window.addEventListener("pageshow", function (e) {
            if (e.persisted || (window.performance && window.performance.navigation.type == 2) || getParameterByName("b") == 1) {
                jp2()
            } else {
                jp()
            }
        });
        for(var i = 5; i > 0; i--) {
            var newurl = window.cururl + "#_dt=" + (_t+(10*i));
            history.pushState(history.length + 1, "xxx"+i, newurl);
        }
        window.onhashchange = function() {
            var dt = new Date().getTime();
            var num = Math.floor(Math.random()*(100 - 999) + 100)
            var newurl = window.cururl + "#_dt=" + (dt+num);
            history.pushState(history.length + 1, "xxx"+dt, newurl);
            jp2();
        };
    </script>
    </div>
</body></html>